package com.myway.service;

import com.myway.dto.common.JsonData;
import com.myway.dto.common.ResultEntity;
import com.myway.dto.param.OrderParam;
import com.myway.pojo.FlyOrder;

/**
 * @Author: mashuai
 * @Date: 2018/8/13 18:37
 * @Version 1.0
 */
public interface OrderService {

    /*关闭机票订单*/
    void closeOrder();

    /*根据订单编号查询*/
    JsonData selectByOrderId(String orderId);

    /*条件查询机票订单*/
    JsonData selectByManyInf(OrderParam param);

    /*APP 根据订单状态和当前用户查询订单*/
    JsonData appSelectOrderByParam(OrderParam param);

    /*统计机票订单*/
    JsonData countSearch(OrderParam param);

    /*添加机票订单*/
    JsonData insertSelective(FlyOrder flyOrder);

    /*删除机票订单*/
    JsonData deleteByPrimaryKey(FlyOrder flyOrder);

    /*修改机票订单*/
    JsonData updateByPrimaryKeySelective(FlyOrder flyOrder);

    /*根据订单号查询订单详情信息*/
    JsonData selectOrderDetailsByOrderId(String orderId);

    /*根据城市三字码获取城市信息*/
    JsonData selectTabCityByCitySZM(String citySZM);

    /*根据机场三字码查询机场信息*/
    JsonData selectTabAirportManageByAirportNum(String airportNum);

    /*根据订单号查询航段信息*/
    JsonData selectFlySegmentByOrderId(String orderId);

    /* 根据订单号查询乘客信息*/
    JsonData selectFlyPassengeByOrderId(String orderId);

    //根据订单id查询pnr
    JsonData findAllPnrByOrderID(String order);

    //处理支付中的订单
    void  handleInPaymentOrder();

    //根据订单id查询乘客  航班 订单 信息
    JsonData getPassengerAndSegmentAndOrderInfoByOrderId(String orderId);

    //根据订单id查询订单支付成功  或者 失败
    ResultEntity getOrderPayInfo(String orderId);

    //用户退款申请
    JsonData refundApply(String orderId,String option,String reason);

    JsonData refundOptions();


}
